package edu.hit.irlab.tms.datamapping;

import java.io.Serializable;

/**
 * 
 * @author chuter
 *
 */
public class Token implements Serializable {
	private static final long serialVersionUID = 1989L;
	private int id;
	private String content;
	private String tag;
	private int sentenceId;
	// the position of the token in the document
	private int startdocumentpos;
	private int enddocumentpos;
	// the parser result, which is expressed in the form
	// giving it's father id and the relation tag between them 
	private int fatertokenid;
	private String parse_relation;
//	private HashMap<String, String> nlpresmap;
//	
//	public Token() {
//		nlpresmap = new HashMap<String, String>();
//	}
	
	/**
	 * @return the id
	 */
	public int getId() {
		return id;
	}
	/**
	 * @param id the id to set
	 */
	public void setId(int id) {
		this.id = id;
	}
	/**
	 * @return the content
	 */
	public String getContent() {
		return content;
	}
	/**
	 * @param content the content to set
	 */
	public void setContent(String content) {
		this.content = content;
	}
	/**
	 * @return the pos
	 */
	public String getPos() {
		return tag;
	}
	/**
	 * @param pos the pos to set
	 */
	public void setPos(String tag) {
		this.tag = tag;
	}
	
	/**
	 * @return the sentenceId
	 */
	public int getSentenceId() {
		return sentenceId;
	}
	/**
	 * @param sentenceId the sentenceId to set
	 */
	public void setSentenceId(int sentenceId) {
		this.sentenceId = sentenceId;
	}
	
	/** Set the end pos in the document of the token  */
	public void setenddocumentpos(int pos) {
		enddocumentpos = pos;
	}
	
	/** Get the end pos in the document of the token  */
	public int getenddocumentpos() {
		return enddocumentpos;
	}
	
	/** Set the end pos in the document of the token  */
	public void setstartdocumentpos(int pos) {
		startdocumentpos = pos;
	}
	
	/** Get the end pos in the document of the token  */
	public int getstartdocumentpos() {
		return startdocumentpos;
	}
	
	public void setparseresult(int fatherid, String relation_tag) {
		fatertokenid = fatherid;
		parse_relation = relation_tag;
	}
	
	public int getfatherid() {
		return fatertokenid;
	}
	
	public String getrelation() {
		return parse_relation;
	}
//	/**
//	 * Set the result from the specific nlp basic tool
//	 * 
//	 * @param toolname
//	 * @param resval
//	 */
//	public void setnlpres(String toolname, String resval) {
//		nlpresmap.put(toolname, resval);
//	}
//	
//	/**
//	 * Get the specific nlp result by giving the name
//	 * @param resname
//	 * @return
//	 */
//	public String getnlpres(String toolname) {
//		return nlpresmap.get(toolname);
//	}
	
}
